<template>
  <div>
    <button @click="btnClk">点击出遮罩层</button>
    <Model :isDialog.sync='isDialog'>
        <template>
            姓名：<input type="text">
            年龄：<input type="text">
        </template>
    </Model>
  </div>
</template>

<script>
import Model from "@/components/Model";
export default {
  data() {
    return {
        isDialog:false
    };
  },
  methods:{
      btnClk(){
          this.isDialog = true
      }
  },
  components: {
    Model,
  },
};
</script>

<style scoped>
</style>